times = 3
while times:
    username = input('pls input your name:')
    password = input('pls input your password:')
    if username == 'admin' and password == '123456':
        print('login success!')
        break
    else:
        times -= 1
        print('用户名或密码错误，剩余{}次'.format(times))

